# Contributor: Michał Polański <michal@polanski.me>
# Maintainer: Michał Polański <michal@polanski.me>
pkgname=catatonit
pkgver=0.1.7
pkgrel=0
pkgdesc="Container init that is so simple it's effectively brain-dead"
url="https://github.com/openSUSE/catatonit"
license="GPL-3.0-or-later"
arch="all"
makedepends="autoconf automake libtool"
source="$pkgname-$pkgver.tar.xz::https://github.com/openSUSE/catatonit/releases/download/v$pkgver/catatonit.tar.xz
	fix-build.patch
	"
options="!check" # no test suite

prepare() {
	default_prepare
	autoreconf -fi
}

build() {
	./configure --prefix=/usr
	make
}

package() {
	make DESTDIR="$pkgdir" install

	install -d "$pkgdir"/usr/libexec/podman
	ln -s /usr/bin/$pkgname "$pkgdir"/usr/libexec/podman/$pkgname
}

sha512sums="
5eb554918539458630cad2229d34b66cd357fdcdfe61732792812ac6c77dd0fa73ec9927d057324d0fd038ef6416f04a1544a886d7b188adfa1712e59b454152  catatonit-0.1.7.tar.xz
21a571f9f4f157b47178352cea19123ef8e536dec45ec5e5427031640135625a9ad372d61d6cf7e9fcbf6d3e446a7cd87e3031c2d111211258e8fbd2e0688497  fix-build.patch
"
